package com.taldh.design.patterns.factories.abstractfacotories.impl;

/**
 * date: 2020/5/24
 *
 * @author 袁小黑
 * @version 1.0.0
 */

public class InsuranceFactoryMaker {

    public InsuranceFactory getInsuranceFactory(InsuranceCompany insuranceCompany) {
        if (InsuranceCompany.PINGAN.equals(insuranceCompany)) {
            return new PinganInsuranceCompany();
        } else {
            return new TaikangInsuranceCompany();
        }
    }
}
